def count(text: str, parameter: str) -> int:
    times = 0
    if parameter in text:     
        times += 1
        start = text.index(parameter) + 1
        text = text[start:]
        while parameter in text:
            # print(text)
            times += 1
            start = text.index(parameter) + 1
            text = text[start:]
    return times


if __name__ == '__main__':
    # print(count('abcdefg', 'def'))
    print(count('101010101010101010101', '101'))
    # print(count('mississippi', 'iss'))